package com.xjust.service.impl;

import com.xjust.Mapper.DeptmentMapper;
import com.xjust.service.DeptmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class DeptmentServiceImpl implements DeptmentService {
    @Autowired
   private DeptmentMapper deptmentMapper;
    //获取所有部门
    @Override
    public List<Map<String, Object>> getDeptment() {
        List<Map<String, Object>> list = deptmentMapper.selectDeptment();
        return list;
    }
    //根据类型查找部门
    @Override
    public List<Map<String, Object>> getDeptmentListBydeptType(String deptType) {
        List<Map<String, Object>> list =deptmentMapper.selectDeptmentListBydeptType(deptType);
    return list;
    }
}
